﻿
@{
    Layout = "~/Views/Shared/_Layout.cshtml";
    ViewData["Title"] = "湖北省检察院档案管理系统 - 库藏统计";
}

@section Head{
    <link rel="stylesheet" href="~/layuiadmin/style/statistics.css" media="all">
    <style>
        .layui-tab-card > .layui-tab-title .layui-this{background:#fff;}
    </style>
}


<div class="layui-fluid layui-form">
    <div class="layui-tab layui-tab-card" lay-filter="tab-echart">
        <ul class="layui-tab-title">
            <li class="layui-this" index='1'>
                诉讼年度报表
            </li>
            <li index='2'>
                文书年度报表      
            </li>
        </ul>
        <div class="layui-tab-content">
            <div class="layui-tab-item layui-show ">
                <table class="layui-hide" id="test1" lay-filter="test1"></table>
            </div>
            <div class="layui-tab-item ">
                <table class="layui-hide" id="test2" lay-filter="test2"></table>
            </div>
        </div>
    </div>
</div>


@section scripts{
    <script type="text/html" id="toolbarCon1">
        <form class="layui-form toolbarCon1" action="">
            <div class="layui-inline">
                <input type="text" class="layui-input worddate1" id="txtFYear" placeholder="年度" lay-event='txtFYear' name="txtFYear">
            </div>
            <div class="layui-inline">
                <button class="layui-btn layui-btn-sm" lay-event='js'>搜索</button>
            </div>
        </form>
    </script>
    <script type="text/html" id="toolbarCon2">
        <form class="layui-form toolbarCon1" action="">
            <div class="layui-inline">
                <input type="text" class="layui-input worddate1" id="txtFYear" placeholder="年度" lay-event='txtFYear' name="txtFYear">
            </div>
            <div class="layui-inline">
                <button class="layui-btn layui-btn-sm" lay-event='js'>搜索</button>
            </div>
        </form>
    </script>
    <script src="../../layuiadmin/layui/layui.js"></script>
    <script>
        layui.use(['form', 'element', 'table', 'laydate', 'jquery'], function () {
            var element = layui.element, table = layui.table, laydate = layui.laydate, form = layui.form, $ = layui.jquery;


            var table1 = table.render({
                elem: '#test1'
                , data: [{ 'thisYear': '20011', 'JuanShu': '10', 'JianShu': '100', 'PageCount': '200', 'TiaoShu': '400' }, { 'thisYear': '2002', 'JuanShu': '10', 'JianShu': '100', 'PageCount': '200', 'TiaoShu': '400' }]
                , toolbar: '#toolbarCon1' //开启头部工具栏，并为其绑定左侧模板
                , defaultToolbar: ['filter', 'exports', 'print']
                , title: '用户数据表'
                , totalRow: true
                , cols: [[
                    { field: 'thisYear', title: '年度', align: 'center', totalRowText: "合计:" }
                    , { field: 'JuanShu', title: '卷数', align: 'center', totalRow: true }
                    , { field: 'JianShu', title: '件数', align: 'center', totalRow: true }
                    , { field: 'PageCount', title: '页数', align: 'center', totalRow: true }
                    , { field: 'TiaoShu', title: '条数', align: 'center', totalRow: true }
                ]]
            });
            var table2 = table.render({
                elem: '#test2'
                , data: [{ 'thisYear': '2001', 'JuanShu': '10', 'JianShu': '100', 'PageCount': '200', 'TiaoShu': '400' }, { 'thisYear': '2002', 'JuanShu': '10', 'JianShu': '100', 'PageCount': '200', 'TiaoShu': '400' }]
                , toolbar: '#toolbarCon1' //开启头部工具栏，并为其绑定左侧模板
                , defaultToolbar: ['filter', 'exports', 'print']
                , title: '用户数据表'
                , totalRow: true
                , cols: [[
                    { field: 'thisYear', title: '年度', align: 'center', totalRowText: "合计:" }
                    , { field: 'JuanShu', title: '卷数', align: 'center', totalRow: true }
                    , { field: 'JianShu', title: '件数', align: 'center', totalRow: true }
                    , { field: 'PageCount', title: '页数', align: 'center', totalRow: true }
                    , { field: 'TiaoShu', title: '条数', align: 'center', totalRow: true }
                ]]
            });
            laydate.render({
                elem: '#date1'
                , range: '~',
                format: 'yyyyMMdd'
            })
            laydate.render({
                elem: '#txtFYear',
                type: 'year'
            })
        })
    </script>
}